package com.ztgf.commodity.models.service;

import com.baomidou.mybatisplus.service.IService;
import com.ztgf.commodity.models.bo.CommodityCategoryParamRelationSaveBO;
import com.ztgf.commodity.models.dto.CommodityCategoryParamRelationDTO;
import com.ztgf.commodity.models.vo.CommodityCategoryParamRelationVO;

import java.util.List;

/**
 * 商品分类参数关系表服务
 *
 * @author chenyu.wang
 * @Date 2020-06-15 10:30:06
 */
public interface ICommodityCategoryParamRelationService extends IService<CommodityCategoryParamRelationDTO> {
    boolean add(CommodityCategoryParamRelationSaveBO saveBO);

    /**
     * description: 根据顶级分类id获取商品参数信息，用于商品上传页
     * param: [categoryId]
     * author: chenyu.wang
     * date: 2020-06-15
     * return: java.util.List<com.ztgf.commodity.models.vo.CommodityCategoryParamRelationVO>
     */
    List<CommodityCategoryParamRelationVO> queryList(Long categoryId, Long brandId,String filterName);

    /**
     * description: 批量添加
     * param: [userId, categoryId, ids]
     * author: chenyu.wang
     * date: 2020-07-07
     * return: boolean
     */
    void addList(Long userId, Long categoryId, String ids);

    /**
     * description: 根据分类id删除关联参数信息
     * param: [categoryId]
     * author: chenyu.wang
     * date: 2020-07-29
     * return: boolean
     */
    boolean deleteAccordingToCategoryId(Long categoryId);
}
